n = eval(input())
m = 60
list = []
i = 2
while i <= n:
    if n % i == 0:
        list.append(i)
        n //= i
        i -= 1
    i += 1
for i in list:
    print(i, end=" ")
